/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package edu.upf.grupE.impl;

import edu.upf.grupE.GenericMessage;

/**
 *
 * @author xday666
 */
public class ILMessage implements GenericMessage {

    private String to,  iD,  from;
    /**
     *Differnet types of message.
     */
    public static final int SEARCHPICTURE = 1;
    /**
     *
     */
    public static final int CHAT = 2;
    /**
     *
     */
    public int type;

    /**
     * Sets the destination.
     * @param to Destination of the message
     */
    public final void setTo(String to) {
        this.to = to;
    }

    /**
     * Sets the ID of the packet.
     * @param ID The ID
     */
    public final void setID(final String ID) {
        iD = ID;
    }

    /**
     * Sets the type of message.
     * @param typeint
     */
    public final void setType(final int typeint) {
        type = typeint;
    }

    /**
     * Sets the origin of the message.
     * @param strfrom
     */
    public final void setFrom(final String strfrom) {
        from = strfrom;
    }

    /**
     * Returns the destination of the message.
     * @return The destination
     */
    public String getTo() {
        return to;
    }

    /**
     * Returns the ID of the message.
     * @return The ID of the message
     */
    public String getID() {
        return iD;
    }

    /**
     * Returns the type of the message.
     * @return The type of message
     */
    public int getType() {
        return type;
    }

    /**
     * Return the origin of the message.
     * @return
     */
    public String getFrom() {
        return from;
    }
}
